import './styles/index.less'
import { createApp } from 'vue'
import { createPinia } from 'pinia'
import App from './App.vue'
import ElementPlus from 'element-plus'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import 'element-plus/dist/index.css'
// import draggable from '@/../lib/vuedraggable/dist/vuedraggable.umd.js'
import draggable from 'vuedraggable'
import ContainerWidgets from '@/components/form-designer/form-widget/container-widget/index'
import ContainerRender from '@/components/form-render/container/index'

const app = createApp(App)

app.use(ContainerWidgets)
app.use(ContainerRender)
app.use(createPinia())
app.use(ElementPlus)
// eslint-disable-next-line vue/multi-word-component-names
app.component('draggable', draggable)
// 注册所有图标
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}
app.mount('#app')
